﻿<%@ Control Language="VB" AutoEventWireup="false" CodeFile="Header.ascx.vb" Inherits="FrontEnd_Control_Header" %>
<%@ Import Namespace="Cls_Common" %>
<script type="text/javascript">
    $(function () {

        //for enter search
        $("#<%= txtSearch.ClientID %>").keypress(function (e) {
            if (e.keyCode == 13) {
                $("#<%=lbtSearch.ClientID()%>").click();
                return false;
            }
        });


        $("#<%= lbtSearch.ClientID %>").click(function () {
            if (($("#<%= txtSearch.ClientID %>").val() == "") || ($("#<%= txtSearch.ClientID %>").val().length < 2)) {
                alert("Vui lòng nhập từ khóa");
                $("#<%= txtSearch.ClientID %>").focus();
                return false;
            }
        });


    });
</script>
<div id="header">
    <div id="logo" style="margin-left: 5px;">
        <a href='<%=MainDomain%>'>
            <img src='<%=MainDomain & "FrontEnd/images/logo.png"%>' alt="logo" style="margin-top: 15px;" /></a></div>
    <div class="search">
        <div id="Banner1_Panel2">
            <asp:TextBox ID="txtSearch" runat="server" MaxLength="50" CssClass="keyword" placeholder="Nhập từ khóa"></asp:TextBox>
            <asp:LinkButton ID="lbtSearch" CssClass="quicksearch" CausesValidation="false" runat="server" />
        </div>
    </div>
    <ul id="menutop-header">
        <%  If Session("UserName") Is Nothing Then%>
        <li><a href='<%=MainDomain & "dang-nhap.html"%>'>
            Đăng nhập</a></li>
        <li><a href='<%=MainDomain & "dang-ky.html"%>'>Đăng ký</a></li>
        <% Else%>
        <li class="MyAdmin" style="height: 30px; line-height: 30px;">Chào bạn <b><a style="color: #FF1206"
            href='<%=MainDomain & "myAdmin.html"%>'>
            <%= Session("UserName")%>
            [<%= Session("UserCode")%>
            ]</a></b> </li>
        <li>
            <asp:HyperLink ID="lbtnExit" runat="server" Text="Thoát" NavigateUrl="~/Logout.aspx"></asp:HyperLink>
        </li>
        <% End If%>
        <li><a href='<%=MainDomain & "Content/tro-giup-hoi-dap-120.html"%>'>Hỏi đáp</a></li>
        <li><a href='https://www.facebook.com/lolitastorevn' target="_blank">Hỗ trợ trực tuyến</a>
        </li>
    </ul>
    <div class="giohang-khung">
        <div class="ico-giohang">
            <asp:Literal ID="lblNumberItem" runat="server" Text="0"></asp:Literal></div>
        <a href='<%=MainDomain & "gio-hang.html"%>' class="shoppingCart" id="GiohangTop">Xem
            giỏ hàng</a></div>
</div>
<asp:HiddenField ID="hidCate" runat="server" Value="0" />
